<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8" />
    <meta name="description" content="慧报考高考志愿测评系统是由长期从事高考志愿指导、教育统计与测量工作的资深专家和教育行业资深软件工程师共同研发，同时提供电脑版、手机版和微信版，主要功能有计划查询、院校查询、专业查询、位次查询、专业测评、智能选校、志愿测评等，系统以大数据为基础为考生提供必要的指导和参考，极大方便考生志愿填报"/>
    <meta name="keywords" content="慧报考,志愿填报,高考志愿测评系统,湖北高考,高考分数,计划查询,院校查询,专业查询,位次查询,专业测评,智能选校,志愿测评,录取查询"/>
    <link rel="icon" type="image/x-icon" href="/favicon.ico" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>慧报考</title>
    <link rel="stylesheet" href="/css/moblie.css">
    <link rel="stylesheet" href="/css/md.css">
</head>
<script src="./js/jquery.js"></script>
<body>

    <#include "header.ftl"/>

<div class="bkd-menu flex">
    <a  onclick="switchTab('tab1Con',this)" class="f1 active">线路安排</a>
    <a  onclick="switchTab('tab2Con',this)" class="f1">参会报名</a>
    <a  onclick="switchTab('tab3Con',this)" class="f1 ">增值服务</a>
    <a  onclick="switchTab('tab4Con',this)" class="f1 ">往届回顾</a>
</div>
<div class="bkd-container">
    <div class="tabCon tab1Con">
         <#if line_content??>
             <div class="z3-line oft ">${line_content}</div>
          </#if>
    </div>
      <div class="tabCon tab2Con" style="display: none">
          <#if attachments?? && attachments?size gt 0>
              <div class="z2-list">
                  <#list attachments as attach>
                      <div class="item">
                          <div class="item-text">${attach.name}</div>
                          <a class="down" href="${attach.url}">
                              <img src="/image/m_xiazai.png">
                              下载</a>
                      </div>
                  </#list>
              </div>
          </#if>
          <#if examination_content??>
              <div class="z3 concat oft">${examination_content}</div>
          </#if>
      </div>
    <div class="tabCon tab3Con" style="display: none">
        <#if increment_content??>
            <div class="z3 increment oft">${increment_content}</div>
        </#if>
     </div>
    <div class="tabCon tab4Con" style="display: none">
        <div class="z4-img-list" id="imgViewer">
            <i class="list-i-before">
            </i><i></i><i></i>
        </div>
        <a class="a-top" href="#" style="display: none"> <span>顶部</span></a>
    </div>
</div>
<#--    <#include "footer.ftl"/>-->
</body>
</html>
<script>

   function switchTab(tabPage,el) {
        $('.tabCon').hide()
        $('.'+ tabPage).show()
        $(el).addClass('active').siblings().removeClass('active')
   }
    var currentPage = 1
    function scrollTop(){
        return Math.max(
            //chrome
            document.body.scrollTop,
            //firefox/IE
            document.documentElement.scrollTop);
    }
    //获取页面文档的总高度
    function documentHeight(){
//现代浏览器（IE9+和其他浏览器）和IE8的document.body.scrollHeight和document.documentElement.scrollHeight都可以
        return Math.max(document.body.scrollHeight,document.documentElement.scrollHeight);
    }
    function throttle(fn,time){
        let canUse = true ; // 设置一个开关
        return function(){
            if(!canUse ){ return false } // 如果开关已经关掉了就不用往下了
            // if(canUse) fn.apply(this,arguments)//fn放这里是立即执行
            canUse = false  // 利用闭包刚进来的时候关闭开关
            fn()
            setTimeout(function() {
                canUse = true // 执行完才打开开关
            },time)
        }
    }
    function windowHeight(){
        return (document.compatMode == "CSS1Compat")?
            document.documentElement.clientHeight:
            document.body.clientHeight;
    }
    function addtempdata() {
        $.ajax('api/consultation/webList?page='+currentPage+'&num=15',{
            success:function (res) {
                var data = res.data.rows
                data.forEach(function (item) {
                    $('.list-i-before').before('<div class="zx4-pic-a"   href="'+item+'"><img   data-original="'+item+'"  class="z4-img-item" src = "'+item+'" > </div>')
                })
                currentPage++
                if(res.data.rows.length == 0) {
                    currentPage--
                }
            }
        })
    }
    $(function () {

        $('.nav-c-1').trigger('click')
        var thfn = throttle(addtempdata,500)
        $(window).on('scroll',function() {
            if(scrollTop()  > 400) {
                $('.a-top').show()
            }else {
                $('.a-top').hide()
            }
            if(scrollTop() + windowHeight() > (documentHeight() / 2 + 400) ){
                thfn()
            }
        });
        addtempdata()
    })
</script>

